Ext.define('AM.view.List',{
	extend:'Ext.grid.Panel',
	title:'Gird Demo',
	alias:'widget.userList', 
	height: 350,
	width: 500,
	
	columns:[
		{header:'ID',dataIndex:'id',hidden:true},
		{header:'Name',dataIndex:'name',field:'textfield'},
		{ header: 'Age', dataIndex: 'age'},
		{ header: 'Email', dataIndex: 'email',flex:1,field:{xtype:'textfield',allowBlank:false}}
	],
	tbar:[
			{text:'添加'},'-',
			{id:'delete',text:'删除'},'-',
			{text:'查看'},'-',
			{text:'修改'}
	],
	dockedItems:[{
		xtype:'pagingtoolbar',
		//store: Ext.create('AM.store.Users'),
		store:'Users',
		dock: 'bottom',
		displayInfo:true
	}],
	plugins: [
        Ext.create('Ext.grid.plugin.CellEditing', {
            clicksToEdit: 1
        })
    ],
    //selType: 'rowmodel',
	selType:'checkboxmodel',//设置选择模式
	multiSelect:true,//设置为多选
	//store: Ext.create('AM.store.Users'),
	store:'Users',
	initComponent:function(){
		this.callParent(arguments);
	}
});